<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title></title>
    <script src="../js/angular.min.js"></script>
</head>
<body>
<div ng-app="myApp" ng-controller="myCtrl">
    <form>
        <p>First Name:</p>
        <input ng-model="form.firstName">
        <p>Last Name</p>
        <input ng-model="form.lastName"><br><br>
        <button ng-click="reset()">Reset</button>
        <p>form={{form}}</p>

        <p>master={{master}}</p>
    </form>
</div>
<script>
    var app = angular.module("myApp", []);
    app.controller("myCtrl", function ($scope) {
       /* $scope.form = {"firstName": "John", "lastName": "Doe"};*/
        $scope.master = {"firstName": "John", "lastName": "Doe"};
        $scope.reset = function () {
            $scope.form = angular.copy($scope.master);
        }
        $scope.reset();
    });
</script>
</body>
</html>